Integrand size = 24, antiderivative size = 184 \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\frac {d^2 \cos (a+b x)}{4 b^3}-\frac {(c+d x)^2 \cos (a+b x)}{8 b}+\frac {d^2 \cos (3 a+3 b x)}{216 b^3}-\frac {(c+d x)^2 \cos (3 a+3 b x)}{48 b}-\frac {d^2 \cos (5 a+5 b x)}{1000 b^3}+\frac {(c+d x)^2 \cos (5 a+5 b x)}{80 b}+\frac {d (c+d x) \sin (a+b x)}{4 b^2}+\frac {d (c+d x) \sin (3 a+3 b x)}{72 b^2}-\frac {d (c+d x) \sin (5 a+5 b x)}{200 b^2} \]
[Out]
Time = 0.22 (sec) , antiderivative size = 184, normalized size of antiderivative = 1.00, number of steps used = 11, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {4491, 3377, 2718} \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\frac {d^2 \cos (a+b x)}{4 b^3}+\frac {d^2 \cos (3 a+3 b x)}{216 b^3}-\frac {d^2 \cos (5 a+5 b x)}{1000 b^3}+\frac {d (c+d x) \sin (a+b x)}{4 b^2}+\frac {d (c+d x) \sin (3 a+3 b x)}{72 b^2}-\frac {d (c+d x) \sin (5 a+5 b x)}{200 b^2}-\frac {(c+d x)^2 \cos (a+b x)}{8 b}-\frac {(c+d x)^2 \cos (3 a+3 b x)}{48 b}+\frac {(c+d x)^2 \cos (5 a+5 b x)}{80 b} \]
[In]
[Out]
Rule 2718
Rule 3377
Rule 4491
Rubi steps \begin{align*} \text {integral}& = \int \left (\frac {1}{8} (c+d x)^2 \sin (a+b x)+\frac {1}{16} (c+d x)^2 \sin (3 a+3 b x)-\frac {1}{16} (c+d x)^2 \sin (5 a+5 b x)\right ) \, dx \\ & = \frac {1}{16} \int (c+d x)^2 \sin (3 a+3 b x) \, dx-\frac {1}{16} \int (c+d x)^2 \sin (5 a+5 b x) \, dx+\frac {1}{8} \int (c+d x)^2 \sin (a+b x) \, dx \\ & = -\frac {(c+d x)^2 \cos (a+b x)}{8 b}-\frac {(c+d x)^2 \cos (3 a+3 b x)}{48 b}+\frac {(c+d x)^2 \cos (5 a+5 b x)}{80 b}-\frac {d \int (c+d x) \cos (5 a+5 b x) \, dx}{40 b}+\frac {d \int (c+d x) \cos (3 a+3 b x) \, dx}{24 b}+\frac {d \int (c+d x) \cos (a+b x) \, dx}{4 b} \\ & = -\frac {(c+d x)^2 \cos (a+b x)}{8 b}-\frac {(c+d x)^2 \cos (3 a+3 b x)}{48 b}+\frac {(c+d x)^2 \cos (5 a+5 b x)}{80 b}+\frac {d (c+d x) \sin (a+b x)}{4 b^2}+\frac {d (c+d x) \sin (3 a+3 b x)}{72 b^2}-\frac {d (c+d x) \sin (5 a+5 b x)}{200 b^2}+\frac {d^2 \int \sin (5 a+5 b x) \, dx}{200 b^2}-\frac {d^2 \int \sin (3 a+3 b x) \, dx}{72 b^2}-\frac {d^2 \int \sin (a+b x) \, dx}{4 b^2} \\ & = \frac {d^2 \cos (a+b x)}{4 b^3}-\frac {(c+d x)^2 \cos (a+b x)}{8 b}+\frac {d^2 \cos (3 a+3 b x)}{216 b^3}-\frac {(c+d x)^2 \cos (3 a+3 b x)}{48 b}-\frac {d^2 \cos (5 a+5 b x)}{1000 b^3}+\frac {(c+d x)^2 \cos (5 a+5 b x)}{80 b}+\frac {d (c+d x) \sin (a+b x)}{4 b^2}+\frac {d (c+d x) \sin (3 a+3 b x)}{72 b^2}-\frac {d (c+d x) \sin (5 a+5 b x)}{200 b^2} \\ \end{align*}
Time = 0.84 (sec) , antiderivative size = 127, normalized size of antiderivative = 0.69 \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\frac {-6750 \left (-2 d^2+b^2 (c+d x)^2\right ) \cos (a+b x)-125 \left (-2 d^2+9 b^2 (c+d x)^2\right ) \cos (3 (a+b x))+27 \left (-2 d^2+25 b^2 (c+d x)^2\right ) \cos (5 (a+b x))+30 b d (c+d x) (450 \sin (a+b x)+25 \sin (3 (a+b x))-9 \sin (5 (a+b x)))}{54000 b^3} \]
[In]
[Out]
Time = 2.14 (sec) , antiderivative size = 152, normalized size of antiderivative = 0.83
method | result | size |
parallelrisch | \(\frac {\left (-1125 \left (d x +c \right )^{2} b^{2}+250 d^{2}\right ) \cos \left (3 x b +3 a \right )+\left (675 \left (d x +c \right )^{2} b^{2}-54 d^{2}\right ) \cos \left (5 x b +5 a \right )+750 b d \left (d x +c \right ) \sin \left (3 x b +3 a \right )-270 b d \left (d x +c \right ) \sin \left (5 x b +5 a \right )+\left (-6750 \left (d x +c \right )^{2} b^{2}+13500 d^{2}\right ) \cos \left (x b +a \right )+13500 b d \left (d x +c \right ) \sin \left (x b +a \right )-7200 b^{2} c^{2}+13696 d^{2}}{54000 b^{3}}\) | \(152\) |
risch | \(-\frac {\left (x^{2} d^{2} b^{2}+2 b^{2} c d x +b^{2} c^{2}-2 d^{2}\right ) \cos \left (x b +a \right )}{8 b^{3}}+\frac {d \left (d x +c \right ) \sin \left (x b +a \right )}{4 b^{2}}+\frac {\left (25 x^{2} d^{2} b^{2}+50 b^{2} c d x +25 b^{2} c^{2}-2 d^{2}\right ) \cos \left (5 x b +5 a \right )}{2000 b^{3}}-\frac {d \left (d x +c \right ) \sin \left (5 x b +5 a \right )}{200 b^{2}}-\frac {\left (9 x^{2} d^{2} b^{2}+18 b^{2} c d x +9 b^{2} c^{2}-2 d^{2}\right ) \cos \left (3 x b +3 a \right )}{432 b^{3}}+\frac {d \left (d x +c \right ) \sin \left (3 x b +3 a \right )}{72 b^{2}}\) | \(195\) |
derivativedivides | \(\frac {\frac {a^{2} d^{2} \left (-\frac {\sin \left (x b +a \right )^{2} \cos \left (x b +a \right )^{3}}{5}-\frac {2 \cos \left (x b +a \right )^{3}}{15}\right )}{b^{2}}-\frac {2 a c d \left (-\frac {\sin \left (x b +a \right )^{2} \cos \left (x b +a \right )^{3}}{5}-\frac {2 \cos \left (x b +a \right )^{3}}{15}\right )}{b}-\frac {2 a \,d^{2} \left (-\frac {\left (x b +a \right ) \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{3}+\frac {\sin \left (x b +a \right )^{3}}{45}+\frac {2 \sin \left (x b +a \right )}{15}+\frac {\left (x b +a \right ) \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{5}-\frac {\sin \left (x b +a \right )^{5}}{25}\right )}{b^{2}}+c^{2} \left (-\frac {\sin \left (x b +a \right )^{2} \cos \left (x b +a \right )^{3}}{5}-\frac {2 \cos \left (x b +a \right )^{3}}{15}\right )+\frac {2 c d \left (-\frac {\left (x b +a \right ) \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{3}+\frac {\sin \left (x b +a \right )^{3}}{45}+\frac {2 \sin \left (x b +a \right )}{15}+\frac {\left (x b +a \right ) \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{5}-\frac {\sin \left (x b +a \right )^{5}}{25}\right )}{b}+\frac {d^{2} \left (-\frac {\left (x b +a \right )^{2} \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{3}+\frac {4 \cos \left (x b +a \right )}{15}+\frac {4 \left (x b +a \right ) \sin \left (x b +a \right )}{15}+\frac {2 \left (x b +a \right ) \sin \left (x b +a \right )^{3}}{45}+\frac {2 \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{135}+\frac {\left (x b +a \right )^{2} \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{5}-\frac {2 \left (x b +a \right ) \sin \left (x b +a \right )^{5}}{25}-\frac {2 \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{125}\right )}{b^{2}}}{b}\) | \(466\) |
default | \(\frac {\frac {a^{2} d^{2} \left (-\frac {\sin \left (x b +a \right )^{2} \cos \left (x b +a \right )^{3}}{5}-\frac {2 \cos \left (x b +a \right )^{3}}{15}\right )}{b^{2}}-\frac {2 a c d \left (-\frac {\sin \left (x b +a \right )^{2} \cos \left (x b +a \right )^{3}}{5}-\frac {2 \cos \left (x b +a \right )^{3}}{15}\right )}{b}-\frac {2 a \,d^{2} \left (-\frac {\left (x b +a \right ) \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{3}+\frac {\sin \left (x b +a \right )^{3}}{45}+\frac {2 \sin \left (x b +a \right )}{15}+\frac {\left (x b +a \right ) \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{5}-\frac {\sin \left (x b +a \right )^{5}}{25}\right )}{b^{2}}+c^{2} \left (-\frac {\sin \left (x b +a \right )^{2} \cos \left (x b +a \right )^{3}}{5}-\frac {2 \cos \left (x b +a \right )^{3}}{15}\right )+\frac {2 c d \left (-\frac {\left (x b +a \right ) \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{3}+\frac {\sin \left (x b +a \right )^{3}}{45}+\frac {2 \sin \left (x b +a \right )}{15}+\frac {\left (x b +a \right ) \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{5}-\frac {\sin \left (x b +a \right )^{5}}{25}\right )}{b}+\frac {d^{2} \left (-\frac {\left (x b +a \right )^{2} \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{3}+\frac {4 \cos \left (x b +a \right )}{15}+\frac {4 \left (x b +a \right ) \sin \left (x b +a \right )}{15}+\frac {2 \left (x b +a \right ) \sin \left (x b +a \right )^{3}}{45}+\frac {2 \left (2+\sin \left (x b +a \right )^{2}\right ) \cos \left (x b +a \right )}{135}+\frac {\left (x b +a \right )^{2} \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{5}-\frac {2 \left (x b +a \right ) \sin \left (x b +a \right )^{5}}{25}-\frac {2 \left (\frac {8}{3}+\sin \left (x b +a \right )^{4}+\frac {4 \sin \left (x b +a \right )^{2}}{3}\right ) \cos \left (x b +a \right )}{125}\right )}{b^{2}}}{b}\) | \(466\) |
[In]
[Out]
none
Time = 0.25 (sec) , antiderivative size = 166, normalized size of antiderivative = 0.90 \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\frac {27 \, {\left (25 \, b^{2} d^{2} x^{2} + 50 \, b^{2} c d x + 25 \, b^{2} c^{2} - 2 \, d^{2}\right )} \cos \left (b x + a\right )^{5} - 5 \, {\left (225 \, b^{2} d^{2} x^{2} + 450 \, b^{2} c d x + 225 \, b^{2} c^{2} - 26 \, d^{2}\right )} \cos \left (b x + a\right )^{3} + 780 \, d^{2} \cos \left (b x + a\right ) - 30 \, {\left (9 \, {\left (b d^{2} x + b c d\right )} \cos \left (b x + a\right )^{4} - 26 \, b d^{2} x - 26 \, b c d - 13 \, {\left (b d^{2} x + b c d\right )} \cos \left (b x + a\right )^{2}\right )} \sin \left (b x + a\right )}{3375 \, b^{3}} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 382 vs. \(2 (172) = 344\).
Time = 0.58 (sec) , antiderivative size = 382, normalized size of antiderivative = 2.08 \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\begin {cases} - \frac {c^{2} \sin ^{2}{\left (a + b x \right )} \cos ^{3}{\left (a + b x \right )}}{3 b} - \frac {2 c^{2} \cos ^{5}{\left (a + b x \right )}}{15 b} - \frac {2 c d x \sin ^{2}{\left (a + b x \right )} \cos ^{3}{\left (a + b x \right )}}{3 b} - \frac {4 c d x \cos ^{5}{\left (a + b x \right )}}{15 b} - \frac {d^{2} x^{2} \sin ^{2}{\left (a + b x \right )} \cos ^{3}{\left (a + b x \right )}}{3 b} - \frac {2 d^{2} x^{2} \cos ^{5}{\left (a + b x \right )}}{15 b} + \frac {52 c d \sin ^{5}{\left (a + b x \right )}}{225 b^{2}} + \frac {26 c d \sin ^{3}{\left (a + b x \right )} \cos ^{2}{\left (a + b x \right )}}{45 b^{2}} + \frac {4 c d \sin {\left (a + b x \right )} \cos ^{4}{\left (a + b x \right )}}{15 b^{2}} + \frac {52 d^{2} x \sin ^{5}{\left (a + b x \right )}}{225 b^{2}} + \frac {26 d^{2} x \sin ^{3}{\left (a + b x \right )} \cos ^{2}{\left (a + b x \right )}}{45 b^{2}} + \frac {4 d^{2} x \sin {\left (a + b x \right )} \cos ^{4}{\left (a + b x \right )}}{15 b^{2}} + \frac {52 d^{2} \sin ^{4}{\left (a + b x \right )} \cos {\left (a + b x \right )}}{225 b^{3}} + \frac {338 d^{2} \sin ^{2}{\left (a + b x \right )} \cos ^{3}{\left (a + b x \right )}}{675 b^{3}} + \frac {856 d^{2} \cos ^{5}{\left (a + b x \right )}}{3375 b^{3}} & \text {for}\: b \neq 0 \\\left (c^{2} x + c d x^{2} + \frac {d^{2} x^{3}}{3}\right ) \sin ^{3}{\left (a \right )} \cos ^{2}{\left (a \right )} & \text {otherwise} \end {cases} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 375 vs. \(2 (166) = 332\).
Time = 0.26 (sec) , antiderivative size = 375, normalized size of antiderivative = 2.04 \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\frac {3600 \, {\left (3 \, \cos \left (b x + a\right )^{5} - 5 \, \cos \left (b x + a\right )^{3}\right )} c^{2} - \frac {7200 \, {\left (3 \, \cos \left (b x + a\right )^{5} - 5 \, \cos \left (b x + a\right )^{3}\right )} a c d}{b} + \frac {3600 \, {\left (3 \, \cos \left (b x + a\right )^{5} - 5 \, \cos \left (b x + a\right )^{3}\right )} a^{2} d^{2}}{b^{2}} + \frac {30 \, {\left (45 \, {\left (b x + a\right )} \cos \left (5 \, b x + 5 \, a\right ) - 75 \, {\left (b x + a\right )} \cos \left (3 \, b x + 3 \, a\right ) - 450 \, {\left (b x + a\right )} \cos \left (b x + a\right ) - 9 \, \sin \left (5 \, b x + 5 \, a\right ) + 25 \, \sin \left (3 \, b x + 3 \, a\right ) + 450 \, \sin \left (b x + a\right )\right )} c d}{b} - \frac {30 \, {\left (45 \, {\left (b x + a\right )} \cos \left (5 \, b x + 5 \, a\right ) - 75 \, {\left (b x + a\right )} \cos \left (3 \, b x + 3 \, a\right ) - 450 \, {\left (b x + a\right )} \cos \left (b x + a\right ) - 9 \, \sin \left (5 \, b x + 5 \, a\right ) + 25 \, \sin \left (3 \, b x + 3 \, a\right ) + 450 \, \sin \left (b x + a\right )\right )} a d^{2}}{b^{2}} + \frac {{\left (27 \, {\left (25 \, {\left (b x + a\right )}^{2} - 2\right )} \cos \left (5 \, b x + 5 \, a\right ) - 125 \, {\left (9 \, {\left (b x + a\right )}^{2} - 2\right )} \cos \left (3 \, b x + 3 \, a\right ) - 6750 \, {\left ({\left (b x + a\right )}^{2} - 2\right )} \cos \left (b x + a\right ) - 270 \, {\left (b x + a\right )} \sin \left (5 \, b x + 5 \, a\right ) + 750 \, {\left (b x + a\right )} \sin \left (3 \, b x + 3 \, a\right ) + 13500 \, {\left (b x + a\right )} \sin \left (b x + a\right )\right )} d^{2}}{b^{2}}}{54000 \, b} \]
[In]
[Out]
none
Time = 0.32 (sec) , antiderivative size = 209, normalized size of antiderivative = 1.14 \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\frac {{\left (25 \, b^{2} d^{2} x^{2} + 50 \, b^{2} c d x + 25 \, b^{2} c^{2} - 2 \, d^{2}\right )} \cos \left (5 \, b x + 5 \, a\right )}{2000 \, b^{3}} - \frac {{\left (9 \, b^{2} d^{2} x^{2} + 18 \, b^{2} c d x + 9 \, b^{2} c^{2} - 2 \, d^{2}\right )} \cos \left (3 \, b x + 3 \, a\right )}{432 \, b^{3}} - \frac {{\left (b^{2} d^{2} x^{2} + 2 \, b^{2} c d x + b^{2} c^{2} - 2 \, d^{2}\right )} \cos \left (b x + a\right )}{8 \, b^{3}} - \frac {{\left (b d^{2} x + b c d\right )} \sin \left (5 \, b x + 5 \, a\right )}{200 \, b^{3}} + \frac {{\left (b d^{2} x + b c d\right )} \sin \left (3 \, b x + 3 \, a\right )}{72 \, b^{3}} + \frac {{\left (b d^{2} x + b c d\right )} \sin \left (b x + a\right )}{4 \, b^{3}} \]
[In]
[Out]
Time = 1.06 (sec) , antiderivative size = 249, normalized size of antiderivative = 1.35 \[ \int (c+d x)^2 \cos ^2(a+b x) \sin ^3(a+b x) \, dx=\frac {780\,d^2\,\cos \left (a+b\,x\right )+130\,d^2\,{\cos \left (a+b\,x\right )}^3-54\,d^2\,{\cos \left (a+b\,x\right )}^5-1125\,b^2\,c^2\,{\cos \left (a+b\,x\right )}^3+675\,b^2\,c^2\,{\cos \left (a+b\,x\right )}^5+780\,b\,d^2\,x\,\sin \left (a+b\,x\right )-1125\,b^2\,d^2\,x^2\,{\cos \left (a+b\,x\right )}^3+675\,b^2\,d^2\,x^2\,{\cos \left (a+b\,x\right )}^5+780\,b\,c\,d\,\sin \left (a+b\,x\right )-2250\,b^2\,c\,d\,x\,{\cos \left (a+b\,x\right )}^3+1350\,b^2\,c\,d\,x\,{\cos \left (a+b\,x\right )}^5+390\,b\,d^2\,x\,{\cos \left (a+b\,x\right )}^2\,\sin \left (a+b\,x\right )-270\,b\,d^2\,x\,{\cos \left (a+b\,x\right )}^4\,\sin \left (a+b\,x\right )+390\,b\,c\,d\,{\cos \left (a+b\,x\right )}^2\,\sin \left (a+b\,x\right )-270\,b\,c\,d\,{\cos \left (a+b\,x\right )}^4\,\sin \left (a+b\,x\right )}{3375\,b^3} \]
[In]
[Out]